Kill gpg agent in package-test.el to avoid a race
authorRob Browning <rlb@defaultvalue.org>
Mon, 10 Oct 2016 22:35:56 +0000 (17:35 -0500)
committerRob Browning <rlb@defaultvalue.org>
Mon, 10 Oct 2016 22:35:56 +0000 (17:35 -0500)
commitbc0af6a40c371ff8f4eaecad134c1831a6d49e75
treef76f708a64eaef29e35635bb58a4a18ae3fcc583
parentb5d8dc19b8431730ea9ab487e00069ac46192f44
Kill gpg agent in package-test.el to avoid a race

package-test.el should no longer fail during clean up.

* Previously a delete-directories call raced with the gpg agent's own
  cleanup process (presumably triggered by the first deletion of one of
  the agent's sockets).  As a result, it looks like the agent could
  delete one of its sockets after delete-directories had decided to
  delete the socket, but before it made the attempt, causing an
  exception.

* To fix the problem, explicitly ask gpg-connect-agent to kill the agent
  before attempting to delete the gnupg home directory.
test/automated/package-test.el